package com.neusoft.service;

import com.neusoft.Dao.ProductDao;
import com.neusoft.model.Product;

import java.util.List;

public class ProductServiceImpl implements IProductService{
    ProductDao productDao = new ProductDao();
    @Override
    public Product selectProductById(Integer id) {
        return productDao.selectProductById(id);
    }

    @Override
    public List<Product> selectProductList() {
        return productDao.selectProductList();
    }

    @Override
    public int insertProduct(Product Product) {
        return productDao.insertProduct(Product);
    }

    @Override
    public int updateProduct(Product Product) {
        return productDao.updateProduct(Product);
    }

    @Override
    public int deleteProductById(Integer id) {
        return productDao.deleteProductById(id);
    }

    @Override
    public List<Product> selectProductListByName(String name) {
        return productDao.selectProductListByName(name);
    }
}
